<template>
  <div class="apply-container">
    <!-- 售后类型 -->
    <van-tabs class="apply-tab" @change="(active, title) => {this.active = active}" animated sticky swipeable color="#e6b873" line-height="2" v-model="active">
      <div slot="nav-left" class="nav-back" @click="$router.back()">
        <van-icon name="arrow-left" />
      </div>
      <van-tab title="全部">
        <applyList :status="-1"></applyList>
      </van-tab>
      <van-tab title="处理中">
        <applyList :status="0"></applyList>
      </van-tab>
      <van-tab title="已完成">
        <applyList :status="1"></applyList>
      </van-tab>
    </van-tabs>
  </div>
</template>

<script>
import applyList from './list.vue'

export default {
  components: {
    applyList
  },
  name: 'applyIndex',
  data () {
    return {
      active: 0
    }
  },
  activated () {
    this.active = parseInt(this.$route.query.status)+1;
  }
}
</script>

<style lang="scss">
.apply-container{
  .apply-tab{
  }
}
</style>
